home *** CD-ROM | disk | FTP | other *** search
/ Champak 120 / Vol 120.iso / games / space_bo.swf / scripts / DefineSprite_198 / frame_4 / DoAction.as
Encoding:
Text File  |  2010-11-09  |  409 b   |  19 lines

  1. this._x += _parent.speed + moveX;
  2. this._y -= moveY;
  3. moveY -= floatFactor;
  4. rikDX = _parent.rik._x - this._x;
  5. rikDY = _parent.rik._y - this._y;
  6. if(rikDX < 10 and rikDX > -60 and rikDY < 15 and rikDY > -65)
  7. {
  8.    _parent.riciclesCollected = _parent.riciclesCollected + 1;
  9.    nextFrame();
  10. }
  11. else if(this._y > 425 or this._x < -25 or this._x > 575)
  12. {
  13.    gotoAndStop(1);
  14. }
  15. else
  16. {
  17.    prevFrame();
  18. }
  19.